package org.igeek.config.filter;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @package org.igeek.config.di.ch01
 * @Description 业务逻辑类
 * @Author LittlePunk [296526219@qq.ccom]
 * @Version 2022.1
 * @Date 2023/11/14 10:19
 */
@Service
public class UserService {
    //@Autowired(required = false)  required 如果找不到  就给当前的对象赋值位null
    @Autowired(required = false)
    private UserDao userDao;
    //登录业务逻辑的实现
    public boolean login(String name,String pwd){
        User user = userDao.selectOne(name, pwd);
        System.out.println("UserService.login 业务逻辑");
        return true;
    }
}
